<!DOCTYPE html>
<html lang="zh-CN">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>影视天堂 - 海量高清影视资源</title>
    <!-- 网站图标 -->
    <link rel="shortcut icon" href="{{ url_for('static', filename='images/favicon.ico') }}" type="image/x-icon">
    <link rel="icon" href="{{ url_for('static', filename='images/favicon.ico') }}" type="image/x-icon">
    <script src="https://cdn.tailwindcss.com"></script>
    <script src="https://cdn.socket.io/4.4.1/socket.io.min.js"></script>
    <script src="https://cdn.tailwindcss.com"></script>
    <link href="https://cdn.jsdelivr.net/npm/font-awesome@4.7.0/css/font-awesome.min.css" rel="stylesheet">
    <script src="https://cdn.jsdelivr.net/npm/chart.js@4.4.8/dist/chart.umd.min.js"></script>
    <link href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap" rel="stylesheet">



    <style type="text/tailwindcss">
        @layer utilities {
            .content-auto {
                content-visibility: auto;
            }
            .scrollbar-hide {
                -ms-overflow-style: none;
                scrollbar-width: none;
            }
            .scrollbar-hide::-webkit-scrollbar {
                display: none;
            }
            .text-shadow {
                text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
            }
            .bg-gradient-movie {
                background: linear-gradient(to bottom, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.8) 100%);
            }
            .hover-scale {
                transition: transform 0.3s ease;
            }
            .hover-scale:hover {
                transform: scale(1.05);
            }
            .backdrop-blur-sm {
                backdrop-filter: blur(4px);
            }
            .card-gradient {
                background: linear-gradient(180deg, rgba(0, 0, 0, 0) 50%, rgba(0, 0, 0, 0.8) 100%);
            }
            /* 添加 active 类的样式 */
            .content-slide.active {
                opacity: 1;
                pointer-events: auto;
                z-index: 10;
            }
            .content-slide:not(.active) {
                opacity: 0;
                pointer-events: none;
                z-index: 0;
            }
        }
    </style>
</head>

<body class="font-inter bg-dark-blue text-light min-h-screen flex flex-col">
    <!-- 导航栏 -->
    <header class="sticky top-0 z-50 bg-dark/90 backdrop-blur-md transition-all duration-300">
        <div class="container mx-auto px-4 py-3 flex items-center justify-between">
            <!-- Logo -->
            <a href="/" class="flex items-center space-x-2">
                <div class="w-10 h-10 rounded-lg bg-primary flex items-center justify-center">
                    <i class="fa fa-film text-2xl text-white"></i>
                </div>
                <span class="text-xl font-bold text-white">影视天堂</span>
            </a>

            <!-- 主导航 - 桌面版 -->
            <nav class="hidden md:flex items-center space-x-8">
                <a href="/" class="text-white font-medium hover:text-primary transition-colors">首页</a>
                <div class="relative group">
                    <a href="#" class="text-white font-medium hover:text-primary transition-colors flex items-center">
                        电影 <i class="fa fa-angle-down ml-1"></i>
                    </a>
                    <div class="absolute left-0 mt-2 w-48 rounded-md shadow-lg bg-dark-blue/95 backdrop-blur-sm opacity-0 invisible group-hover:opacity-100 group-hover:visible transition-all duration-300 z-50">
                        <div class="py-1">
                            <a href="/?t1=1&t2=6" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">动作片</a>
                            <a href="/?t1=1&t2=7" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">喜剧片</a>
                            <a href="/?t1=1&t2=8" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">爱情片</a>
                            <a href="/?t1=1&t2=9" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">科幻片</a>
                            <a href="/?t1=1&t2=10" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">恐怖片</a>
                            <a href="/?t1=1&t2=11" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">剧情片</a>
                            <a href="/?t1=1&t2=12" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">战争片</a>
                            <a href="/?t1=1&t2=20" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">惊悚片</a>
                            <a href="/?t1=1&t2=21" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">家庭片</a>
                            <a href="/?t1=1&t2=22" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">古装片</a>
                            <a href="/?t1=1&t2=23" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">历史片</a>
                            <a href="/?t1=1&t2=24" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">悬疑片</a>
                            <a href="/?t1=1&t2=25" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">犯罪片</a>
                            <a href="/?t1=1&t2=26" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">灾难片</a>
                            <a href="/?t1=1&t2=27" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">纪录片</a>
                            <a href="/?t1=1&t2=28" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">短片</a>
                            <a href="/?t1=1&t2=29" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">动画片</a>
                            <a href="/?t1=1&t2=45" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">西部片</a>
                            <a href="/?t1=1&t2=5" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">伦理片</a>
                        </div>
                    </div>
                </div>
                <div class="relative group">
                    <a href="#" class="text-white font-medium hover:text-primary transition-colors flex items-center">
                        连续剧 <i class="fa fa-angle-down ml-1"></i>
                    </a>
                    <div class="absolute left-0 mt-2 w-48 rounded-md shadow-lg bg-dark-blue/95 backdrop-blur-sm opacity-0 invisible group-hover:opacity-100 group-hover:visible transition-all duration-300 z-50">
                        <div class="py-1">
                            <a href="/?t1=2&t2=13" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">国产剧</a>
                            <a href="/?t1=2&t2=14" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">香港剧</a>
                            <a href="/?t1=2&t2=15" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">韩国剧</a>
                            <a href="/?t1=2&t2=16" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">欧美剧</a>
                            <a href="/?t1=2&t2=30" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">台湾剧</a>
                            <a href="/?t1=2&t2=31" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">日本剧</a>
                            <a href="/?t1=2&t2=32" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">海外剧</a>
                            <a href="/?t1=2&t2=33" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">泰国剧</a>
                        </div>
                    </div>
                </div>
                <div class="relative group">
                    <a href="#" class="text-white font-medium hover:text-primary transition-colors flex items-center">
                        动漫 <i class="fa fa-angle-down ml-1"></i>
                    </a>
                    <div class="absolute left-0 mt-2 w-48 rounded-md shadow-lg bg-dark-blue/95 backdrop-blur-sm opacity-0 invisible group-hover:opacity-100 group-hover:visible transition-all duration-300 z-50">
                        <div class="py-1">
                            <a href="/?t1=4&t2=38" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">国产动漫</a>
                            <a href="/?t1=4&t2=40" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">日韩动漫</a>
                            <a href="/?t1=4&t2=39" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">欧美动漫</a>
                        </div>
                    </div>
                </div>
                <div class="relative group">
                    <a href="#" class="text-white font-medium hover:text-primary transition-colors flex items-center">
                        综艺 <i class="fa fa-angle-down ml-1"></i>
                    </a>
                    <div class="absolute left-0 mt-2 w-48 rounded-md shadow-lg bg-dark-blue/95 backdrop-blur-sm opacity-0 invisible group-hover:opacity-100 group-hover:visible transition-all duration-300 z-50">
                        <div class="py-1">
                            <a href="/?t1=3&t2=34" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">大陆综艺</a>
                            <a href="/?t1=3&t2=35" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">港台综艺</a>
                            <a href="/?t1=3&t2=36" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">日韩综艺</a>
                            <a href="/?t1=3&t2=37" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">欧美综合</a>
                        </div>
                    </div>
                </div>
                <div class="relative group">
                    <a href="#" class="text-white font-medium hover:text-primary transition-colors flex items-center">
                        体育 <i class="fa fa-angle-down ml-1"></i>
                    </a>
                    <div class="absolute left-0 mt-2 w-48 rounded-md shadow-lg bg-dark-blue/95 backdrop-blur-sm opacity-0 invisible group-hover:opacity-100 group-hover:visible transition-all duration-300 z-50">
                        <div class="py-1">
                            <a href="/?t1=17&t2=41" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">足球</a>
                            <a href="/?t1=17&t2=42" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">篮球</a>
                            <a href="/?t1=17&t2=18" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">NBA</a>
                        </div>
                    </div>
                </div>
                <div class="relative group">
                    <a href="#" class="text-white font-medium hover:text-primary transition-colors flex items-center">
                        短剧 <i class="fa fa-angle-down ml-1"></i>
                    </a>
                    <div class="absolute left-0 mt-2 w-48 rounded-md shadow-lg bg-dark-blue/95 backdrop-blur-sm opacity-0 invisible group-hover:opacity-100 group-hover:visible transition-all duration-300 z-50">
                        <div class="py-1">
                            <a href="/?t1=46&t2=47" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">现代都市</a>
                            <a href="/?t1=46&t2=48" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">脑洞悬疑</a>
                            <a href="/?t1=46&t2=49" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">年代穿越</a>
                            <a href="/?t1=46&t2=50" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">古装仙侠</a>
                            <a href="/?t1=46&t2=51" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">反转爽剧</a>
                            <a href="/?t1=46&t2=52" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">女频恋爱</a>
                            <a href="/?t1=46&t2=53" class="block px-4 py-2 text-sm text-gray-light hover:bg-primary/20 hover:text-white">成长逆袭</a>
                        </div>
                    </div>
                </div>
            </nav>

            <!-- 搜索框 -->
            <!-- 搜索框（修改为表单形式） -->
            <form action="/search" method="get" class="relative flex-grow max-w-md mx-4">
                <input type="text" name="keyword" placeholder="搜索电影、电视剧、纪录片..."
                       class="w-full py-2 pl-4 pr-10 rounded-full bg-gray-dark/50 border border-gray-medium/30 focus:outline-none focus:ring-2 focus:ring-primary/50 focus:border-primary text-white placeholder-gray-light/70">
                <button type="submit" class="absolute right-3 top-1/2 transform -translate-y-1/2 text-gray-light hover:text-white transition-colors">
                    <i class="fa fa-search"></i>
                </button>
            </form>

            <!-- 移动端菜单按钮 -->
            <button class="md:hidden text-white" id="mobile-menu-button">
                <i class="fa fa-bars text-xl"></i>
            </button>
        </div>

        <!-- 移动端导航菜单 -->
        <div class="md:hidden bg-dark-blue/95 backdrop-blur-md absolute w-full left-0 top-full shadow-lg transform -translate-y-full opacity-0 invisible transition-all duration-300" id="mobile-menu">
            <div class="container mx-auto px-4 py-3">
                <nav class="flex flex-col space-y-3">
                    <a href="#" class="text-white font-medium hover:text-primary transition-colors py-2 border-b border-gray-dark/30">首页</a>
                    <div class="relative group">
                        <button class="text-white font-medium hover:text-primary transition-colors flex items-center justify-between w-full py-2 border-b border-gray-dark/30">
                            电影 <i class="fa fa-angle-down ml-1 transition-transform group-hover:rotate-180"></i>
                        </button>
                        <div class="pl-4 space-y-2 py-2 bg-gray-dark/20 rounded-lg mt-1 opacity-0 h-0 overflow-hidden group-hover:opacity-100 group-hover:h-auto transition-all duration-300">
                            <a href="#" class="block py-1 text-sm text-gray-light hover:text-white">动作片</a>
                            <a href="#" class="block py-1 text-sm text-gray-light hover:text-white">喜剧</a>
                            <a href="#" class="block py-1 text-sm text-gray-light hover:text-white">爱情</a>
                            <a href="#" class="block py-1 text-sm text-gray-light hover:text-white">科幻</a>
                            <a href="#" class="block py-1 text-sm text-gray-light hover:text-white">恐怖</a>
                            <a href="#" class="block py-1 text-sm text-gray-light hover:text-white">剧情</a>
                            <a href="#" class="block py-1 text-sm text-gray-light hover:text-white">战争</a>
                            <a href="#" class="block py-1 text-sm text-gray-light hover:text-white">记录片</a>
                            <a href="#" class="block py-1 text-sm text-gray-light hover:text-white">伦理</a>
                        </div>
                    </div>
                    <div class="relative group">
                        <button class="text-white font-medium hover:text-primary transition-colors flex items-center justify-between w-full py-2 border-b border-gray-dark/30">
                            连续剧 <i class="fa fa-angle-down ml-1 transition-transform group-hover:rotate-180"></i>
                        </button>
                        <div class="pl-4 space-y-2 py-2 bg-gray-dark/20 rounded-lg mt-1 opacity-0 h-0 overflow-hidden group-hover:opacity-100 group-hover:h-auto transition-all duration-300">
                            <a href="#" class="block py-1 text-sm text-gray-light hover:text-white">国产剧</a>
                            <a href="#" class="block py-1 text-sm text-gray-light hover:text-white">韩剧</a>
                            <a href="#" class="block py-1 text-sm text-gray-light hover:text-white">美剧</a>
                            <a href="#" class="block py-1 text-sm text-gray-light hover:text-white">泰剧</a>
                            <a href="#" class="block py-1 text-sm text-gray-light hover:text-white">港剧</a>
                        </div>
                    </div>
                    <a href="#" class="text-white font-medium hover:text-primary transition-colors py-2 border-b border-gray-dark/30">动漫</a>
                    <a href="#" class="text-white font-medium hover:text-primary transition-colors py-2 border-b border-gray-dark/30">综艺</a>
                    <a href="#" class="text-white font-medium hover:text-primary transition-colors py-2 border-b border-gray-dark/30">体育</a>
                    <a href="#" class="text-white font-medium hover:text-primary transition-colors py-2 border-b border-gray-dark/30">综艺解说</a>
                </nav>
            </div>
        </div>
    </header>

    <!-- 主要内容 -->
    <main class="flex-grow">
        <!-- 内容轮播区域 -->
        <section class="relative h-[60vh] min-h-[400px] bg-dark-blue/90 overflow-hidden">
            <!-- 内容容器 -->
            <div class="container mx-auto px-6 md:px-12 h-full flex items-center">
                <!-- 左对齐内容卡片 -->
                <div class="max-w-2xl w-full">
                    <!-- 轮播内容 -->
                    <div id="content-carousel" class="relative">
                        <!-- 轮播指示器 - 固定在顶部 -->
                        <div class="absolute top-6 left-0 flex space-x-2 z-20">
                            <button class="content-indicator w-3 h-3 rounded-full bg-primary opacity-100 transition-all duration-300 hover:scale-125"
                                data-index="0"></button>
                            <button class="content-indicator w-3 h-3 rounded-full bg-primary opacity-50 transition-all duration-300 hover:scale-125"
                                data-index="1"></button>
                            <button class="content-indicator w-3 h-3 rounded-full bg-primary opacity-50 transition-all duration-300 hover:scale-125"
                                data-index="2"></button>
                        </div>

                        <!-- 内容卡片 1 -->
                        <div class="content-slide active opacity-100 transition-opacity duration-700 z-10" data-index="0">
                            <!-- 调整位置：将标签移到指示器下方 -->
                            <div class="mb-4 pt-20">
                                <span class="inline-block bg-secondary/90 text-white px-3 py-1 rounded-full text-sm font-medium mr-2">热门推荐</span>
                                <span class="inline-block bg-primary/90 text-white px-3 py-1 rounded-full text-sm font-medium">动作/科幻</span>
                            </div>
                            <h1 class="text-[clamp(2rem,5vw,3.5rem)] font-bold text-white text-shadow leading-tight mb-4">星际探索</h1>
                            <p class="text-[clamp(1rem,2vw,1.25rem)] text-gray-light/90 text-shadow mb-8">在遥远的宇宙深处，一位勇敢的宇航员踏上了探索未知的旅程。</p>
                            <div class="flex flex-wrap gap-4 mb-8">
                                <!-- 修改为 a 标签并添加 href 属性 -->
                                <a href="https://zyjiexi.com/player/?url=https://vip.lzcdn2.com/20220517/6774_e088bb46/index.m3u8"
                                    class="flex items-center space-x-2 bg-primary hover:bg-primary/90 text-white px-6 py-3 rounded-full transition-all duration-300 shadow-lg hover:shadow-primary/30 hover-scale no-underline cursor-pointer"
                                    target="_blank">
                                    <i class="fa fa-play-circle-o text-xl"></i>
                                    <span class="font-medium">立即观看</span>
                                </a>
                            </div>
                            <div class="flex items-center space-x-4 text-gray-light">
                                <div class="flex items-center">
                                    <i class="fa fa-star text-yellow-400 mr-1"></i>
                                    <span class="font-medium">9.0</span>
                                    <span class="text-gray-medium/70 ml-1">/10</span>
                                </div>
                                <div class="flex items-center">
                                    <i class="fa fa-eye mr-1"></i>
                                    <span>4.2M 次观看</span>
                                </div>
                                <div class="flex items-center">
                                    <i class="fa fa-calendar mr-1"></i>
                                    <span>2023-06-02</span>
                                </div>
                            </div>
                        </div>

                        <!-- 内容卡片 2 - 速度与激情10 -->
                        <div class="content-slide opacity-0 absolute top-0 left-0 right-0 transition-opacity duration-700 z-10" data-index="1"> <!-- 增加z-index -->
                            <div class="mb-4 pt-12">
                                <span class="inline-block bg-secondary/90 text-white px-3 py-1 rounded-full text-sm font-medium mr-2">热门推荐</span>
                                <span class="inline-block bg-primary/90 text-white px-3 py-1 rounded-full text-sm font-medium">动作/犯罪</span>
                            </div>
                            <h1 class="text-[clamp(2rem,5vw,3.5rem)] font-bold text-white text-shadow leading-tight mb-4">速度与激情10</h1>
                            <p class="text-[clamp(1rem,2vw,1.25rem)] text-gray-light/90 text-shadow mb-8">
                                多米尼克·托雷托和他的家人必须面对史上最致命的对手。这个神秘的敌人与多米尼克的过去有着密切的联系，他决心让托雷托付出代价。
                            </p>

                            <!-- 按钮与评分信息横向排列 -->
                            <div class="flex flex-wrap items-center gap-8 mb-12">
                                <a href="https://zyjiexi.com/player/?url=https://vip.lz-cdn3.com/20230609/19446_bd6c3340/index.m3u8"
                                   class="flex items-center space-x-2 bg-primary hover:bg-primary/90 text-white px-6 py-3 rounded-full transition-all duration-300 shadow-lg hover:shadow-primary/30 hover-scale no-underline cursor-pointer"
                                   target="_blank">
                                    <i class="fa fa-play-circle-o text-xl"></i>
                                    <span class="font-medium">立即观看</span>
                                </a>

                                <!-- 评分和观看信息 -->
                                <div class="flex flex-wrap items-center gap-6 text-gray-light">
                                    <div class="flex items-center space-x-1">
                                        <i class="fa fa-star text-yellow-400"></i>
                                        <span class="font-medium">9.5</span>
                                        <span class="text-gray-medium/70 ml-1">/10</span>
                                    </div>
                                    <div class="flex items-center space-x-1">
                                        <i class="fa fa-eye"></i>
                                        <span>3.8M 次观看</span>
                                    </div>
                                    <div class="flex items-center space-x-1">
                                        <i class="fa fa-calendar"></i>
                                        <span>2023-05-19</span>
                                    </div>
                                </div>
                            </div>
                        </div>

                        <!-- 内容卡片 3 - 蜘蛛侠：纵横宇宙 -->
                        <div class="content-slide opacity-0 absolute top-0 left-0 right-0 transition-opacity duration-700 z-10" data-index="2"> <!-- 增加z-index -->
                            <div class="mb-4 pt-12">
                                <span class="inline-block bg-secondary/90 text-white px-3 py-1 rounded-full text-sm font-medium mr-2">热门推荐</span>
                                <span class="inline-block bg-primary/90 text-white px-3 py-1 rounded-full text-sm font-medium">动画/冒险</span>
                            </div>
                            <h1 class="text-[clamp(2rem,5vw,3.5rem)] font-bold text-white text-shadow leading-tight mb-4">蜘蛛侠：纵横宇宙</h1>
                            <p class="text-[clamp(1rem,2vw,1.25rem)] text-gray-light/90 text-shadow mb-8">
                                迈尔斯·莫拉莱斯将穿越多元宇宙，与来自不同维度的蜘蛛侠们联手对抗强大的反派，同时寻找自己在这个多元宇宙中的位置。
                            </p>

                            <!-- 按钮与评分信息横向排列 -->
                            <div class="flex flex-wrap items-center gap-8 mb-12">
                                <a href="https://zyjiexi.com/player/?url=https://vip.lz-cdn16.com/20230810/34698_236177ad/index.m3u8"
                                   class="flex items-center space-x-2 bg-primary hover:bg-primary/90 text-white px-6 py-3 rounded-full transition-all duration-300 shadow-lg hover:shadow-primary/30 hover-scale no-underline cursor-pointer"
                                   target="_blank">
                                    <i class="fa fa-play-circle-o text-xl"></i>
                                    <span class="font-medium">立即观看</span>
                                </a>

                                <!-- 评分和观看信息 -->
                                <div class="flex flex-wrap items-center gap-6 text-gray-light">
                                    <div class="flex items-center space-x-1">
                                        <i class="fa fa-star text-yellow-400"></i>
                                        <span class="font-medium">9.0</span>
                                        <span class="text-gray-medium/70 ml-1">/10</span>
                                    </div>
                                    <div class="flex items-center space-x-1">
                                        <i class="fa fa-eye"></i>
                                        <span>4.2M 次观看</span>
                                    </div>
                                    <div class="flex items-center space-x-1">
                                        <i class="fa fa-calendar"></i>
                                        <span>2023-06-02</span>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </section>
        <!-- 最近更新区域 -->
        <section class="py-12 bg-gradient-to-b from-dark-blue to-dark">
            <div class="container mx-auto px-4">
                <div class="flex items-center justify-between mb-8">
                    <h2 class="text-2xl md:text-3xl font-bold text-white">最近更新</h2>
                    <a href="/movie?pg=1" class="text-primary hover:text-primary/80 flex items-center transition-colors">
                        <span>查看全部</span>
                        <i class="fa fa-angle-right ml-1"></i>
                    </a>
                </div>

                <div class="grid grid-cols-2 sm:grid-cols-3 md:grid-cols-4 lg:grid-cols-5 xl:grid-cols-6 gap-4 md:gap-6">
                    <!-- 内容卡片 1 -->
                    {% for movie in datalist %}
                    <div class="group relative rounded-lg overflow-hidden hover-scale shadow-lg">
                        <div class="aspect-[2/3] relative">
                            <img src="{{ movie.video_cover }}" alt="影视内容海报" class="w-full h-full object-cover transition-transform duration-500 group-hover:scale-110">
                            <div class="absolute inset-0 bg-gradient-movie opacity-0 group-hover:opacity-100 transition-opacity duration-300 flex flex-col justify-end p-3">
                                <div class="flex justify-between items-center mb-1">
                                    <span class="bg-secondary/90 text-white text-xs font-medium px-2 py-0.5 rounded">{{  movie.vod_remarks  }}</span>
                                    <span class="bg-primary/90 text-white text-xs font-medium px-2 py-0.5 rounded">{{ movie.video_release_time }}</span>
                                </div>
                                <button class="w-full bg-white/20 backdrop-blur-sm hover:bg-white/30 text-white py-2 rounded-md transition-colors flex items-center justify-center">
                                    <a href="/movie?id={{ movie.vod_id }}">
                                    <i class="fa fa-play-circle-o mr-1"></i> 播放
                                    </a>
                                </button>
                            </div>
                        </div>
                        <div class="p-2">
                            <h3 class="font-medium text-white truncate">{{ movie.video_name }}</h3>
                            <p class="text-xs text-gray-medium">{{ movie.vod_class }}</p>
                        </div>
                    </div>
                    {% endfor %}

                </div>
            </div>
        </section>
    </main>
    <!-- 页脚 -->
    <footer class="bg-dark pt-12 pb-6">
        <div class="container mx-auto px-4">
            <div class="grid grid-cols-1 md:grid-cols-4 gap-8 mb-8">
                <div>
                    <div class="flex items-center space-x-2 mb-4">
                        <div class="w-10 h-10 rounded-lg bg-primary flex items-center justify-center">
                            <i class="fa fa-film text-2xl text-white"></i>
                        </div>
                        <span class="text-xl font-bold text-white">影视天堂</span>
                    </div>
                    <p class="text-gray-medium mb-4">
                        提供高质量的影视资源，让您随时随地享受精彩内容。
                    </p>
                    <div class="flex space-x-4">
                        <a href="#" class="text-gray-light hover:text-primary transition-colors">
                            <i class="fa fa-facebook"></i>
                        </a>
                        <a href="#" class="text-gray-light hover:text-primary transition-colors">
                            <i class="fa fa-twitter"></i>
                        </a>
                        <a href="#" class="text-gray-light hover:text-primary transition-colors">
                            <i class="fa fa-instagram"></i>
                        </a>
                        <a href="#" class="text-gray-light hover:text-primary transition-colors">
                            <i class="fa fa-youtube-play"></i>
                        </a>
                    </div>
                </div>

                <div>
                    <h3 class="text-lg font-semibold text-white mb-4">快速链接</h3>
                    <ul class="space-y-2">
                        <li><a href="/" class="text-gray-medium hover:text-primary transition-colors">首页</a></li>
                        <li><a href="#" class="text-gray-medium hover:text-primary transition-colors">电影</a></li>
                        <li><a href="#" class="text-gray-medium hover:text-primary transition-colors">连续剧</a></li>
                        <li><a href="#" class="text-gray-medium hover:text-primary transition-colors">动漫</a></li>
                        <li><a href="#" class="text-gray-medium hover:text-primary transition-colors">综艺</a></li>
                    </ul>
                </div>

                <div>
                    <h3 class="text-lg font-semibold text-white mb-4">支持</h3>
                    <ul class="space-y-2">
                        <li><a href="#" class="text-gray-medium hover:text-primary transition-colors">帮助中心</a></li>
                        <li><a href="#" class="text-gray-medium hover:text-primary transition-colors">联系我们</a></li>
                        <li><a href="#" class="text-gray-medium hover:text-primary transition-colors">隐私政策</a></li>
                        <li><a href="#" class="text-gray-medium hover:text-primary transition-colors">使用条款</a></li>
                        <li><a href="#" class="text-gray-medium hover:text-primary transition-colors">常见问题</a></li>
                    </ul>
                </div>

            </div>

            <div class="border-t border-gray-dark/50 pt-6 flex flex-col md:flex-row justify-between items-center">
                <p class="text-gray-medium text-sm mb-4 md:mb-0">
                    &copy; 2023 影视天堂. 保留所有权利.
                </p>
                <div class="flex space-x-4">
                    <a href="#" class="text-gray-medium hover:text-primary transition-colors text-sm">隐私政策</a>
                    <a href="#" class="text-gray-medium hover:text-primary transition-colors text-sm">使用条款</a>
                    <a href="#" class="text-gray-medium hover:text-primary transition-colors text-sm">Cookie 设置</a>
                </div>
            </div>
        </div>
        <!-- 新增二维码容器（固定定位在右下角） -->
        <div class="fixed bottom-6 right-6 z-30 bg-dark-blue/80 backdrop-blur-sm rounded-lg p-3 shadow-lg border border-gray-dark/50">
            <div class="flex flex-col items-center">
                <img src="{{ url_for('static', filename='images/qq.png') }}" alt="联系二维码"
                     class="w-24 h-24 rounded-md border border-gray-medium/30">
                <p class="text-xs text-gray-light mt-2 text-center">扫码联系客服</p>
            </div>
        </div>
    </footer>


    <!-- 这里需要添加 JavaScript 来处理轮播切换和 active 类的添加/移除 -->
    <script>
        const indicators = document.querySelectorAll('.content-indicator');
        const slides = document.querySelectorAll('.content-slide');
        let currentSlideIndex = 0;
        let intervalId;

        indicators.forEach((indicator, index) => {
            indicator.addEventListener('click', () => {
                showSlide(index);
                currentSlideIndex = index;
                resetInterval();
            });
        });

        function showSlide(index) {
            slides.forEach((slide, i) => {
                if (i === index) {
                    slide.classList.add('active');
                } else {
                    slide.classList.remove('active');
                }
            });

            indicators.forEach((indicator, i) => {
                if (i === index) {
                    indicator.style.opacity = '1';
                } else {
                    indicator.style.opacity = '0.5';
                }
            });
        }

        function startInterval() {
            intervalId = setInterval(() => {
                currentSlideIndex = (currentSlideIndex + 1) % slides.length;
                showSlide(currentSlideIndex);
            }, 5000); // 每 5 秒切换一次
        }

        function resetInterval() {
            clearInterval(intervalId);
            startInterval();
        }

        startInterval();


        tailwind.config = {
            theme: {
                extend: {
                    colors: {
                        primary: '#165DFF',
                        secondary: '#FF4D4F',
                        dark: '#1E293B',
                        light: '#F8FAFC',
                        'dark-blue': '#0F172A',
                        'gray-dark': '#334155',
                        'gray-medium': '#64748B',
                        'gray-light': '#CBD5E1'
                    },
                    fontFamily: {
                        inter: ['Inter', 'sans-serif'],
                    },
                }
            }
        }
    </script>
</body>

</html>